package com.dmcb.trade.business.crawlers.article;

import com.dmcb.trade.business.constants.CrawlConstant;
import org.springframework.stereotype.Service;

/**
 *
 * Created by zhoun on 2016/10/8.
 */
@Service
public class JinJiangParser extends BaseParser{

    /**
     * 获取作者选择器
     * @return
     */
    protected String authorNameSelect() {
        return "div.editor";
    }

    /**
     * 获取封面选择器
     * @return
     */
    protected String coverSelect() {
        return "";
    }

    /**
     * 获取正文内容选择器
     * @return
     */
    protected String bodySelect() {
        return "div#Content.content_text";
    }

    /**
     * 获取发布日期选择器
     * @return
     */
    protected String dateSelect() {
        return "div#Time.xinxi>span:eq(1)";
    }

    /**
     * 获取标题选择器
     * @return
     */
    @Override
    protected String titleSelect() {
        return "div#Title";
    }

    /**
     * 网站url链接
     * @return
     */
    @Override
    protected String url() {
        return CrawlConstant.JINJIANGNEWS_URL;
    }

    /**
     * 网站
     * @return
     */
    @Override
    protected String platform() {
        return "晋江新闻网";
    }
}
